package com.ysh.smartplatform.pojo;


import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.ysh.smartplatform.constans.ResultCode;
import com.ysh.smartplatform.valigroup.Insert;
import com.ysh.smartplatform.valigroup.Select;


import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;

@JsonInclude(JsonInclude.Include.NON_EMPTY)
public class SysCategory {

  @NotNull(groups = {Select.class},message = "{\"code\": "+ ResultCode.PARAM_CONTENT_EMPTY +",\"msg\": \"没有传递id\"}")
  private Long cId;

  @NotEmpty(groups = {Insert.class},message = "{\"code\": "+ ResultCode.PARAM_CONTENT_EMPTY +",\"msg\": \"没有传递分类名称\"}")
  private String categoryName;

  private String txCommand;

  private String rxCommand;

  private String commandName;

  private Long status;//1 是正常,0是删除

  //JsonIgnore拆成两个单词，就是Json和Ignore，Ignore的意思是忽略，所以可以简单的翻译一下就是生成json的时候忽略某个属性。
  @JsonIgnore
  private java.util.Date createTime;
  @JsonIgnore
  private String createBy;
  @JsonIgnore
  private java.util.Date updateTime;
  @JsonIgnore
  private String updateBy;


  public String getRxCommand() {
    return rxCommand;
  }

  public void setRxCommand(String rxCommand) {
    this.rxCommand = rxCommand;
  }


  public long getCId() {
    return cId;
  }

  public void setCId(long cId) {
    this.cId = cId;
  }


  public String getUpdateBy() {
    return updateBy;
  }

  public void setUpdateBy(String updateBy) {
    this.updateBy = updateBy;
  }


  public String getCreateBy() {
    return createBy;
  }

  public void setCreateBy(String createBy) {
    this.createBy = createBy;
  }


  public long getStatus() {
    return status;
  }

  public void setStatus(long status) {
    this.status = status;
  }


  public String getCommandName() {
    return commandName;
  }

  public void setCommandName(String commandName) {
    this.commandName = commandName;
  }


  public String getCategoryName() {
    return categoryName;
  }

  public void setCategoryName(String categoryName) {
    this.categoryName = categoryName;
  }


  public java.util.Date getUpdateTime() {
    return updateTime;
  }

  public void setUpdateTime(java.util.Date updateTime) {
    this.updateTime = updateTime;
  }


  public java.util.Date getCreateTime() {
    return createTime;
  }

  public void setCreateTime(java.util.Date createTime) {
    this.createTime = createTime;
  }


  public String getTxCommand() {
    return txCommand;
  }

  public void setTxCommand(String txCommand) {
    this.txCommand = txCommand;
  }

}
